//
//  File.h
//  mytest
//
//  Created by 杨岑 on 7/15/14.
//
//

#ifndef __mytest__File__
#define __mytest__File__

#include "cocos2d.h"
#include "cocos-ext.h"

using namespace cocos2d;
using namespace cocos2d::extension;

class TestLayer: public Layer
{
public:
    typedef Layer super;
    
    CREATE_FUNC(TestLayer)
    
    void initLayout();
    virtual bool init();
    virtual void onEnter();
    virtual void onExit();
    
    void testMenuItemClick(Ref* sender);
    void testButtonClick(Ref* sender, Control::EventType eventType);
    
private:
    void fadeMeOut();
    
private:
    Layer* _ccbiLayer;
    Layer* _colorLayer;
    Label* _helloLabel;
    Layer* _bgLayer;
    Sprite* _bgSprite;
    Sprite* _bk;
    Sprite* _sprites[10];
    size_t _numSprites;
    ControlButton* _testButton;
    MenuItemImage* _testMenuItem;
};

#endif /* defined(__mytest__File__) */
